﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;

namespace Fayshine.VA
{
    public partial class LoginScreen : UserControl
    {
        public LoginScreen()
        {
            InitializeComponent();
            this.Loaded += new RoutedEventHandler(LoginScreen_Loaded);
        }

        void LoginScreen_Loaded(object sender, RoutedEventArgs e)
        {
            double height = this.ActualHeight;
            double width = this.ActualWidth;
        }
        private void PasswordBox_KeyUp(object sender, KeyEventArgs e)
        {
            if (e.Key == Key.Enter)
            {
                object obj = this.Height;
                ContentControl contentControl = this.Parent as ContentControl;
                if (contentControl != null)
                {
                    contentControl.Content = new MainPage();
                }
            }
        }

        private void enterButton_Click(object sender, RoutedEventArgs e)
        {
            object obj = this.Height;
            ContentControl contentControl = this.Parent as ContentControl;
            if (contentControl != null)
            {
                windowSoundsElement.Play();
                contentControl.Content = new MainPage();
            }
        }
    }
}
